package com.springboot.template.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
 * 安全密钥信息对象 security_key_info
 * 
 * @author Zhang Yu
 * @date 2024-05-28
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class SecurityKeyInfo implements Serializable
{

    /** 主键ID */
    private Integer id;

    /** 密钥内容 */
    private String content;

    /** 密钥类型(1:RSA 公钥,2:RSA 私钥,3:AES密钥) */
    private Integer type;

    /** 渠道id,可理解为关联的子类id,为-1时候表示是自己生成的 */
    private String channelId;

    /** 0:无效,1:有效 */
    private Integer status;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    /** 更新时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    /** 过期时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date expireTime;

    /** 备注 */
    private String remark;
}
